import fly from "./fly";

export const getHispitalListApi = function(params) {
	return fly.get("/member/hisHospital/list", params);
};

//获取用户信息
export const getInfo = function(params) {
	return fly.get(`/app/member/getInfo/${params}`, );

}

// 
export const listByIds = function(params) {
	return fly.get(`/resource/oss/listByIds/${params}`, );

}
//微信登录
export const wxlogin = function(params) {
	return fly.post(`/wxAuth/login`,params, );
}
//退出登录
export const logout = function(params) {
	return fly.post(`/wxAuth/logout`,params, { requiresToken: true });
}
/**
 * 查询医院科室列表
 * @param query
 * @returns {*}
 */

export const listDep = (params) => {
	return fly.get(`/app/dep/list`);
};
//获取科室详情信息
export const depDetails = (params) => {
	return fly.get(`/app/dep/${params}`);
};
//获取医生列表
export const doctorList = (params) => {
	return fly.get(`/app/doctor/list`,params);
};
//获取医生详细信息
export const doctorDetails = (params) => {
	return fly.get(`/app/doctor/${params}`);
};
//获取就诊卡列表
export const patient = (params) => {
	return fly.get(`/app/patient/list`);
};

//删除就诊卡
export const patientDelete = (params) => {
	return fly.delete(`/app/patient/${params}`);
};

//删除用户信息
export const memberDelete = (params) => {
	return fly.delete(`/app/member/${params}`);
};

//新增就诊卡
export const addPatient = (params) => {
	return fly.post(`/app/patient`,params);
};
//修改就诊卡
export const putPatient = (params) => {
	return fly.put(`/app/patient`,params);
};

//申请挂号退款
export const putReg = (params) => {
	
	return fly.put(`/app/registration`,params);
};

//新增挂号
export const addRegistration = (params) => {
	return fly.post(`/app/registration`,params);
};

//获取挂号记录列表
export const getRegistrations = (params) => {
	return fly.get(`/app/registration/list`,params);
};

//获取挂号信息
export const registrationdetails = (params) => {
	return fly.get(`/app/registration/${params}`);
};
//取消挂号
export const delRegistration = (params) => {
	return fly.get(`/app/registration/cancel`,params);
};
//挂号支付请求
export const payOrders = (params) => {
	return fly.get(`/app/registration/pay`,params);
};
//获取科普列表
export const getarticle = (params) => {
	return fly.get(`/app/article/list`,params);
};
//获取科普详细信息
export const getarticledetails = (params) => {
	return fly.get(`/app/article/${params}`);
};
/**
 * 请求用户手机号
 */

export const getPhone = (params) => {
	return fly.get('/auth/getPhoneNumber',params);
};
//获取问卷列表
export const getquestionList = (params) => {
	return fly.get('/app/questionnaire/list',params);
};
//获取问卷信息
export const getquestionOne = (params) => {
	return fly.get('/app/questionnaire/'+params);
};
//新增答题记录
export const setquestionOne = (params) => {
	return fly.post('/app/questionnaireAnswer',params);
};

//获取答题列表
export const getquestionnaireAnswer = (params) => {
	return fly.get('/app/questionnaireAnswer/list',params);
};
//获取答题列表
export const getAnswerOne = (params) => {
	return fly.get(`/app/questionnaireAnswer/${params}`);
};
//获取字典，根据不同字典查询
export const getregistration = (params) => {
	return fly.get(`/app/dict/data/list?dictType=${params}`);
};
//获取字典，根据不同字典查询
export const getSearch = (params) => {
	return fly.get(`/app/Search/list`,params);
};

//获取药房列表
export const getgoods = (params) => {
	return fly.get(`/app/goods/list`,params);
};

//获取药房信息
export const getgoodDetails = (params) => {
	return fly.get(`/app/goods/${params}`);
};
//修改用户信息
export const setMember = (params) => {
	return fly.put(`/app/member`,params);
};

//获取意见
export const getopinion = (params) => {
	return fly.get(`/app/opinion/list`);
};
//获取意见
export const getopinionid = (params) => {
	return fly.get(`/app/opinion/${params}`);
};
//新增意见
export const addOpinion = (params) => {
	return fly.post(`/app/opinion`,params);
};
//新增地址
export const addAddress = (params) => {
	return fly.post(`/app/address/add`,params);
};

//撤销退款
export const removeGoodsOrder = (params) => {
	return fly.put(`/app/goodsOrder/ref`,params);
};

//获取地址
export const address = (params) => {
	return fly.get(`/app/address/pageList`,params);
};
//删除地址
export const deleteAddress = (params) => {
	return fly.delete(`/app/address/remove`,params);
};
//新增评价
export const setgoodsOrderEvaluate = (params) => {
	return fly.post(`app/goodsOrderEvaluate`,params);
};
//新增购物车
export const setgoodsCar = (params) => {
	return fly.post(`/app/goodsCar`,params);
};

//确认收货
export const goodsConfirm= (params) => {
	return fly.put(`/app/goodsOrder/confirm`,params);
};
//获取快递公司
export const getDelivery= (params) => {
	return fly.get(`/system/delivery/allList`,params);
};
//查询购物车
export const goodsCar = (params) => {
	return fly.get(`/app/goodsCar/list`,params);
};

//查询订单评价信息
export const goodsOrderEvaluate = (params) => {
	return fly.get(`/app/goodsOrderEvaluate/${params}`,);
};
//查询评价列表
export const evaluate = (params) => {
	return fly.get(`/app/goods/evaluate/${params}`);
};

//删除购物车

export const delgoodsCar = (params) => {
	
	return fly.delete(`/app/goodsCar/${params}`,);
};

//新增订单
export const setGoodsOrder = (params) => {
	return fly.post(`/app/goodsOrder`,params);
};
//商城订单支付
export const setGoodspay = (params) => {
	return fly.get(`/app/goodsOrder/pay`,params);
};
//申请退款
export const applyGoods = (params) => {
	return fly.put(`/app/goodsOrder`,params);
};
//获取商城订单列表
export const goodsOrderList = (params) => {
	return fly.get(`/app/goodsOrder/list`,params);
};

//删除订单
export const delgoodsOrder = (params) => {
	return fly.delete(`/app/goodsOrder/${params}`,);
};

//获取订单详细信息
export const goodsOrderDetails = (params) => {
	return fly.get(`/app/goodsOrder/${params}`);
};

//获取活动列表
export const getactivity = (params) => {
	return fly.get(`/app/activity/list`);
};



//获取活动详情
export const getactivityid = (params) => {
	return fly.get(`/app/activity/${params}`);
};
